{% extends "base.html" %}
{% block javascript %}
{#<script>#}
{#    $(function () {#}
{#        $('#myModal').modal('hide')#}
{#    });#}
{#</script>#}
<style type="text/css">
    a,a:hover{border:none;text-decoration:none;}
    img,a img{border:none;}
    pre{overflow-x:scroll;background:#ffffff;border:1px solid #cecece;padding:10px;}
    .clear{clear:both;}
    .zoomed > .container{-webkit-filter:blur(3px);filter:blur(3px);}
    .container{width:10px;margin-left:2px;}
    .gallery{list-style-type:none;float:left;}
    .gallery li{float:left;margin-top: -20px; width:10px; height:15px;}
    .gallery li:nth-child(6n){padding-right:0;}
    .gallery li a,.gallery li img{float:left;}
</style>
{% endblock %}
{% block main %}
        <div id="page-wrapper">

            <div class="container-fluid">

                <!-- Page Heading -->
                <div class="row">
                    <div class="col-lg-12">
                        <h3 class="page-header">
                            Client Automation
                        </h3>
                        <ol class="breadcrumb">
                            <li>
                                <i class="fa fa-dashboard"></i>  <a href="../index">Dashboard</a>
                            </li>
                            <li class="active">
                                <i class="fa fa-table"></i> Client Automation
                            </li>
                            <form method="get">
                                <input name="clean_data" class="btn btn-default" style="float: right;margin-top: -28px;" type="submit" value="清空数据"/>
                            </form>
                        </ol>
                    </div>
                </div>
                <div class="row" style="min-height: 450px">
                    <div class="col-lg-12">
{#                        <h4 class="well">Contextual Classes</h4>#}
                        <div class="table-responsive">
                            <table class="table table-hover table-striped" style="height:10px;">
                                <thead>
                                    <tr>
{#                                        <th class="col-lg-1" style="text-align: center">#</th>#}
                                        <th class="col-lg-1" style="text-align: center">平台</th>
                                        <th class="col-lg-1" style="text-align: center">版本</th>
                                        <th class="col-lg-1" style="text-align: center">结果</th>
                                        <th class="col-lg-2" style="text-align: center">模块</th>
                                        <th class="col-lg-2" style="text-align: center">用例</th>
                                        <th class="col-lg-2" style="text-align: center">异常</th>
{#                                        <th class="col-lg-1" style="text-align: center">截图</th>#}
{#                                        <th class="col-lg-1" style="text-align: center">提醒</th>#}
                                        <th class="col-lg-2" style="text-align: center">时间</th>
                                        <th class="col-lg-1" style="text-align: center">操作</th>
                                    </tr>
                                </thead>
                                <tbody>
                                    {% for show in atclientlist.object_list %}
                                        <tr {% if show.result == 0 %}class="danger"{% else %}class="active"{% endif %}>
                                            <div>
{#                                                <td style="text-align: center">{{ show.id }}</td>#}
                                                <td style="text-align: center">{{ show.platform }}</td>
                                                <td style="text-align: center">{{ show.version }}</td>
                                                <td style="text-align: center">{{ show.result_describe }}</td>
                                                <td style="text-align: center">
                                                    <div style="position:relative;width: 150px; word-break:keep-all;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;">
                                                    {{ show.module }}
                                                    </div>
                                                </td>
                                                <td style="text-align: center;">
                                                    <div style="position:relative;width: 200px; word-break:keep-all;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;">
                                                    {{ show.casename }}
                                                    </div>
                                                </td>
                                                <td style="text-align: center">{{ show.exception }}</td>
{#                                                <td style="text-align: center">{{ show.screenshot }}</td>#}
{#                                                <td style="text-align: center">{{ show.notice_describe }}</td>#}
                                                <td style="text-align: center">{{ show.creatdate }}</td>
                                                <td style="text-align: center;">
                                                    <a href="../clientdetail/?id={{ show.id }}" class="glyphicon glyphicon-eye-open" style="margin-left: -10px"></a>
                                                    {% if show.result == 0 %}
                                                        {% if show.screenshot != '' %}
                                                       <div class="container">
                                                            <ul class="gallery">
{#                                                            <li><a href="../../qa/static/images/client/{{ show.screenshot }}" id="img"><img src="../../qa/static/images/client/{{ show.screenshot }}" width="10px" /></a></li>#}
                                                            <li><a href="../../qa/static/images/client/{{ show.screenshot }}" id="img" class="glyphicon glyphicon-picture" style="margin-left: -15px"></a></li>
                                                            </ul>
                                                       <div class="clear"></div>
                                                       {% endif %}
                                                        </div>
{#                                                        <a  id="showimg" href="../clientdetail/?id={{ show.id }}">截图</a>#}
{#                                                        <img src="/qa/static/images/client/login_test_phone_login_09_30_51.png" width="15px" style="margin-top: -6px" class="small_img" onclick="document.getElementById('light').style.display ='block';document.getElementById('fade').style.display='block'"/>#}
{#                                                        <img id="light" class="big_img" src ="/qa/static/images/client/login_test_phone_login_09_30_51.png" onclick = "document.getElementById('light').style.display ='none' ;document.getElementById('fade').style.display='none'"/>#}
{#                                                        <div id="fade" class="black_overlay"></div>#}
                                                    {% endif %}
{#                                                    <div style="position:relative;width: 200px;height:auto;; overflow-x:auto">#}
{#                                                        {{ show.creatdate }}#}
{#                                                    </div>#}
                                                </td>
{#                                                <td style="text-align: center">{{ show.time }}</td>#}
                                            </div>
                                        </tr>
                                    {% empty %}
                                        <tr>
                                            暂无数据
                                        </tr>
                                    {% endfor %}

                                </tbody>
                            </table>
                            <div class="row col-lg-12" style="text-align: center">
                                <span class="step-links">
                                    <ul class="pager">
                                     {% if atclientlist.has_previous %}
                                     <li class="prev">
                                         <a href="?page={{ atclientlist.previous_page_number }}" class="previous">上一页</a>
                                     </li>
                                     {% endif %}
                                     第 {{ atclientlist.number }}/{{ atclientlist.paginator.num_pages }} 页
                                     {% if atclientlist.has_next %}
                                         <li class="prev">
                                             <a href="?page={{ atclientlist.next_page_number }}">下一页</a>
                                         </li>
                                     {% endif %}
                                        <li class="next"><a>共{{ atclient.count }}条</a></li>
                                    </ul>
                                </span>
                            </div>
                        </div>
                    </div>
                </div>
                <!-- /.row -->

            </div>
            <!-- /.container-fluid -->

        </div>
        <!-- /#page-wrapper -->

    </div>
    <!-- /#wrapper -->

    <!-- jQuery -->
    <link rel="stylesheet"  href="../../qa/static/css/zoom.css" media="all" />
    <script src="../../qa/static/js/jquery.js"></script>
{#    <script src="../static/js/sweet-alert.min.js"></script>#}
{#    <link rel="stylesheet" type="text/css" href="../static/css/sweet-alert.css">#}

    <!-- Bootstrap Core JavaScript -->
    <script src="../../qa/static/js/bootstrap.min.js"></script>
    <script src="../../qa/static/js/jquery-1.9.1.min.js"></script>
    <script src="../../qa/static/js/zoom.min.js"></script>
{% endblock %}

</body>

</html>
